﻿<%@ Page Language="C#" EnableViewStateMac="false" MasterPageFile="~/public_page/master_page_common1.master"  AutoEventWireup="true" CodeFile="fill_unicom.aspx.cs" Inherits="recharge_area_fill_unicom" %>
<asp:Content ID="Content3" ContentPlaceHolderID="CPH_Right" runat="Server">
    <script type="text/javascript">
        function check_input(){
            var PayMoney = document.getElementById("<%=TexPayMoney.ClientID %>").getAttribute("value");
            var PREFLAG = document.getElementById("<%=HidPREFLAG.ClientID %>").getAttribute("value");
            if(PayMoney == null || PayMoney == ""){
                    alert("请输入支付金额");
                    return false;
            }else if(PayMoney < 10){
                    alert("缴费金额不能低于10元");
                    return false;       
            }else{
                    var re = /^[0-9]+.?[0-9]*$/;   //判断字符串是否为数字        
                    if (!re.test(PayMoney))    
                      {    
                           alert("请输入数字(例:10.02)");                              
                           return false;    
                      }    

                    if( PREFLAG != "1" ){
                        var PAYNUM = document.getElementById("<%=HidPAYNUM.ClientID %>").getAttribute("value");                                      
                        if(Number(PayMoney) < Number(PAYNUM)){
                            alert("支付金额不能小于账单额度");
                            return false;
                        }else{
                            return true;
                        }
                        return false;
                    }else{
                        var Charge = document.getElementById("<%=HidCHARGE.ClientID %>").getAttribute("value");
                        if((Number(Charge) + Number(PayMoney)) < 0){
                            alert("账户余额不能为负");
                            return false;
                        }else{
                            return true;
                        }
                        return false;
                    }
            }
            
            return false;
        }    
    </script>
    <!--右边内容begin-->
    <div class="crumbs">
        您的位置： <a href="#">充值专区</a><span>&gt;</span> <a href="#">联通手机话费</a>
    </div>
    <div class="step-wrap four-step">
        <ol>
            <li class="first-step first-step-done"><span>1.输入账单信息</span></li>
            <li class="step-done"><span>2.确认信息</span></li>
            <li class="current"><span>3.输入支付信息</span></li>
            <li class="last-step "><span>4.支付成功</span></li>
        </ol>
    </div>
    <!--表单begin-->
    <form id="fill_mobile_bill_form" runat="server" >    
    <div class="apply-from">
        <fieldset>
            <legend><asp:Label ID="LabMessage" runat="server"></asp:Label></legend>
            <asp:Panel ID="PanPay" runat="server" Visible="True">                                
                <div class="fm-item">
                    <label class="fm-label"><asp:Label ID="LabChargeName" runat="server"></asp:Label>：</label>
                    <asp:Label ID="LabCharge" runat="server"></asp:Label>
                </div>        
                <div class="fm-item">
                    <label class="fm-label">支付金额：</label>
                    <asp:TextBox ID="TexPayMoney" runat="server"></asp:TextBox>
                </div>               
                <div class="fm-item">
                    <label class="fm-label">
                    </label>
                    <span class="btn btn-login">
                        <asp:Button ID="Button1" runat="server" Text="下一步"  
                        OnClientClick="return check_input();" onclick="Button1_Click" />
                    </span>
                </div>
            </asp:Panel>
        </fieldset>
    </div>
    <asp:HiddenField ID="HidPREFLAG" runat="server" />
    <asp:HiddenField ID="HidcusNo" runat="server" />
    <asp:HiddenField ID="HidItemNo" runat="server" />
    <asp:HiddenField ID="HidCHARGE" runat="server" />
    <asp:HiddenField ID="HidPAYNUM" runat="server" /> 
    
    
    </form>
    <!--表单end-->
    <div class="help">
        <p>
            <strong>帮助信息：</strong></p>
    </div>
    <div class="notice">
        <p>
            <strong>注意事项：</strong></p>
        <p>
            1、在支付前，请确认帐单是否通过其他渠道付费，以免重复付费。</p>
        <p>
            2、如您的帐单已办理过代扣业务，该类帐单则不能通过付费通网站查询支付。</p>
        <p>
            3、仅限个人用户交纳家庭公用事业费使用。</p>
    </div>
    <!--右边内容end-->
</asp:Content>

